package cn.stylefeng.guns.modular.basic.mapper;

import cn.stylefeng.guns.modular.basic.entity.BasicAddress;
import cn.stylefeng.guns.modular.basic.model.params.BasicAddressParam;
import cn.stylefeng.guns.modular.basic.model.result.BasicAddressResult;
import cn.stylefeng.roses.kernel.model.validator.BaseValidatingParam;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import org.apache.ibatis.annotations.Param;

import java.util.List;
import java.util.Map;

/**
 * <p>
 * 往来地址表 Mapper 接口
 * </p>
 *
 * @author zhucx
 * @since 2019-07-24
 */
public interface BasicAddressMapper extends BaseMapper<BasicAddress> {

    /**
     * 获取列表
     *
     * @author zhucx
     * @Date 2019-07-24
     */
    List<BasicAddressResult> customList(@Param("paramCondition") BasicAddressParam paramCondition);

    /**
     * 获取map列表
     *
     * @author zhucx
     * @Date 2019-07-24
     */
    List<Map<String, Object>> customMapList(@Param("paramCondition") BasicAddressParam paramCondition);

    /**
     * 获取分页实体列表
     *
     * @author zhucx
     * @Date 2019-07-24
     */
    Page<BasicAddressResult> customPageList(@Param("page") Page page, @Param("paramCondition") BasicAddressParam paramCondition, @Param("condition") String condition);

    /**
     * 获取分页map列表
     *
     * @author zhucx
     * @Date 2019-07-24
     */
    Page<Map<String, Object>> customPageMapList(@Param("page") Page page, @Param("paramCondition") BasicAddressParam paramCondition);

	BasicAddressResult findBySpec(@Param("paramCondition")BasicAddressParam param);

    List<BaseValidatingParam> mapAddress();

    List<BasicAddressResult> selectByGeo();

    BasicAddressResult selectAddress(String unit);
}
